import { V8 } from '@/utils/microi.v8'
import { request } from '@/utils/request'

export function historyOther(params?: any, data?: any) {
  return request({ url: '/video/historyOther', method: 'get', params, data })
}

export function historyVideo(params?: any, data?: any) {
  return request({ url: '/video/history', method: 'get', params, data })
}

export async function recommendedVideo(params?: any, data?: any) {
  // var result = V8.request({
  //   Url : V8.ApiBase + '/apiengine/get-short-video-v2',
  //   Data : params,
  // });
  var result = await V8.ApiEngine.Run('get_short_video-v2', {
    ...params
  });
  // var result = request({ url: '/video/recommended', method: 'get', params, data })
  return  result
}

export async function recommendedLongVideo(params?: any, data?: any) {
  var result = await V8.ApiEngine.Run('get-index-content-list-v2', {
    ...params
  });
  return result;
  // return request({ url: '/video/long/recommended/', method: 'get', params, data })
}

export function myVideo(params?: any, data?: any) {
  return request({ url: '/video/my', method: 'get', params, data })
}

export function privateVideo(params?: any, data?: any) {
  return request({ url: '/video/private', method: 'get', params, data })
}

export function likeVideo(params?: any, data?: any) {
  return request({ url: '/video/like', method: 'get', params, data })
}

export function videoComments(params?: any, data?: any) {
  return request({ url: '/video/comments', method: 'get', params, data })
}
